const fs = require("fs"); // 导入fs模块
const path = require("path");
const contentPath = path.resolve(__dirname, "./data.txt");

// 删除
fs.unlink(contentPath, (err) => {
  if (err) return;
  console.log("删除成功");
});
